//---------------------------------------------------------------------------

#include "vcl_stl.h"
#pragma hdrstop
#include <tchar.h>

#include "h_base.h"
#include "h_xml.h"
#include "h_global.h"
using namespace h_base;
using namespace h_xml;

#include "h_g.h"
//---------------------------------------------------------------------------
#include <Vcl.Styles.hpp>
#include <Vcl.Themes.hpp>
USEFORM("t_downloadform.cpp", DownloadForm);
USEFORM("t_cpathform.cpp", CpathForm);
USEFORM("t_dummyform.cpp", DummyForm);
USEFORM("t_eventwaitform.cpp", EventWaitForm);
USEFORM("t_eventfireform.cpp", EventFireForm);
USEFORM("t_confirmform.cpp", ConfirmForm);
USEFORM("t_batform.cpp", BatForm);
USEFORM("t_batchjobform.cpp", BatchJobForm);
USEFORM("t_batlistform.cpp", BatListForm);
USEFORM("t_conditionform.cpp", ConditionForm);
USEFORM("t_concurrencyform.cpp", ConcurrencyForm);
USEFORM("t_mainform.cpp", MainForm);
USEFORM("t_logform.cpp", LogForm);
USEFORM("t_normaljobform.cpp", NormalJobForm);
USEFORM("t_timeform.cpp", TimeForm);
USEFORM("t_selectskinform.cpp", SelectSkinForm);
USEFORM("t_listform.cpp", ListForm);
USEFORM("t_externjobform.cpp", ExternJobForm);
USEFORM("t_excludelistform.cpp", ExcludeListForm);
USEFORM("t_ganttform.cpp", GanttForm);
USEFORM("t_legendform.cpp", LegendForm);
USEFORM("t_groupform.cpp", GroupForm);
USEFORM("t_batchform.cpp", BatchForm);
USEFORM("t_aboutform.cpp", AboutForm);
USEFORM("t_messageform.cpp", MessageForm);
//---------------------------------------------------------------------------
int WINAPI _tWinMain(HINSTANCE, HINSTANCE, LPTSTR, int)
{
   try
   {
       Application->Initialize();
       Application->MainFormOnTaskBar = true;
       Application->CreateForm(__classid(TMainForm), &MainForm);
       Application->CreateForm(__classid(TBatchForm), &BatchForm);
       Application->CreateForm(__classid(TConfirmForm), &ConfirmForm);
       Application->CreateForm(__classid(TLogForm), &LogForm);
       Application->CreateForm(__classid(TGanttForm), &GanttForm);
       Application->CreateForm(__classid(TCpathForm), &CpathForm);
       Application->CreateForm(__classid(TExcludeListForm), &ExcludeListForm);
       Application->CreateForm(__classid(TListForm), &ListForm);
       Application->CreateForm(__classid(TBatListForm), &BatListForm);
       Application->CreateForm(__classid(TBatForm), &BatForm);
       Application->CreateForm(__classid(TDummyForm), &DummyForm);
       Application->CreateForm(__classid(TAboutForm), &AboutForm);
       Application->CreateForm(__classid(TConcurrencyForm), &ConcurrencyForm);
       Application->CreateForm(__classid(TSelectSkinForm), &SelectSkinForm);
       Application->CreateForm(__classid(TLegendForm), &LegendForm);
       Application->CreateForm(__classid(TConditionForm), &ConditionForm);
       Application->CreateForm(__classid(TDownloadForm), &DownloadForm);
       Application->CreateForm(__classid(TNormalJobForm), &NormalJobForm);
       Application->CreateForm(__classid(TExternJobForm), &ExternJobForm);
       Application->CreateForm(__classid(TEventFireForm), &EventFireForm);
       Application->CreateForm(__classid(TBatchJobForm), &BatchJobForm);
       Application->CreateForm(__classid(TGroupForm), &GroupForm);
       Application->CreateForm(__classid(TEventWaitForm), &EventWaitForm);
       Application->CreateForm(__classid(TTimeForm), &TimeForm);
       Application->CreateForm(__classid(TMessageForm), &MessageForm);
       h_g::Init();
       Application->Run();
   }
   catch (Exception &exception)
   {
       Application->ShowException(&exception);
   }
   catch (...)
   {
       try
       {
          throw Exception("");
       }
       catch (Exception &exception)
       {
          Application->ShowException(&exception);
       }
   }
   return 0;
}
//---------------------------------------------------------------------------
